import TabsView from '@/layouts/tabs/TabsView'
import BlankView from '@/layouts/BlankView'
// import PageView from '@/layouts/PageView'

// 路由配置
const options = {
  routes: [
    {
      path: '/login',
      name: '登录页',
      component: () => import('@/pages/login')
    },
    {
      path: '*',
      name: '404',
      component: () => import('@/pages/exception/404'),
    },
    {
      path: '/403',
      name: '403',
      component: () => import('@/pages/exception/403'),
    },
    {
      path: '/',
      name: '首页',
      component: TabsView,
      redirect: '/login',
      children: [
        {
          path: 'demo',
          name: '演示页',
          meta: {
            icon: 'file-ppt'
          },
          component: () => import('@/pages/demo')
        },
        {
          path: 'inspect',
          name: '检查',
          meta: {
            icon: 'file-ppt',
          },
          component: BlankView,
          children: [
            {
              path: 'list',
              name: '检查记录',
              component: () => import('@/pages/inspect/list')
            },
            {
              path: 'my',
              name: '我的审核',
              component: () => import('@/pages/inspect/my')
            },
            {
              path: 'position',
              name: '个人任务中心',
              component: () => import('@/pages/inspect/personal')
            },
          ]
        },
        {
          path: 'user',
          name: '用户',
          meta: {
            icon: 'file-ppt',
          },
          component: BlankView,
          children: [
            {
              path: 'list',
              name: '全部用户',
              component: () => import('@/pages/user/list')
            },
            {
              path: 'my',
              name: '我的用户',
              component: () => import('@/pages/user/my')
            },
            {
              path: 'position',
              name: '岗位用户',
              component: () => import('@/pages/user/position')
            },
          ]
        },
        {
          path: 'organization',
          name: '组织',
          meta: {
            icon: 'file-ppt'
          },
          component: () => import('@/pages/organization/list')
        },
        {
          path: 'table',
          name: '表格',
          meta: {
            icon: 'file-ppt'
          },
          component: () => import('@/pages/table/list')
        },
        {
          path: 'plan',
          name: '计划',
          meta: {
            icon: 'file-ppt'
          },
          component: () => import('@/pages/plan/list')
        },
        {
          path: 'department',
          name: '部门',
          meta: {
            icon: 'file-ppt'
          },
          component: () => import('@/pages/department/list')
        },
        {
          path: 'problem',
          name: '问题',
          meta: {
            icon: 'file-ppt'
          },
          component: () => import('@/pages/problem/list')
        },
        {
          path: 'hiddenDanger',
          name: '隐患',
          meta: {
            icon: 'file-ppt'
          },
          component: () => import('@/pages/hiddenDanger/list')
        },
      ]
    }
  ]
}

export default options
